package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.ClickMapper;
import com.ruoyi.system.domain.Click;
import com.ruoyi.system.service.IClickService;

/**
 * 广告点击Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-04-14
 */
@Service
public class ClickServiceImpl implements IClickService 
{
    @Autowired
    private ClickMapper clickMapper;

    /**
     * 查询广告点击
     * 
     * @param id 广告点击主键
     * @return 广告点击
     */
    @Override
    public Click selectClickById(Long id)
    {
        return clickMapper.selectClickById(id);
    }

    /**
     * 查询广告点击列表
     * 
     * @param click 广告点击
     * @return 广告点击
     */
    @Override
    public List<Click> selectClickList(Click click)
    {
        return clickMapper.selectClickList(click);
    }

    /**
     * 新增广告点击
     * 
     * @param click 广告点击
     * @return 结果
     */
    @Override
    public int insertClick(Click click)
    {
        return clickMapper.insertClick(click);
    }

    /**
     * 修改广告点击
     * 
     * @param click 广告点击
     * @return 结果
     */
    @Override
    public int updateClick(Click click)
    {
        return clickMapper.updateClick(click);
    }

    /**
     * 批量删除广告点击
     * 
     * @param ids 需要删除的广告点击主键
     * @return 结果
     */
    @Override
    public int deleteClickByIds(Long[] ids)
    {
        return clickMapper.deleteClickByIds(ids);
    }

    /**
     * 删除广告点击信息
     * 
     * @param id 广告点击主键
     * @return 结果
     */
    @Override
    public int deleteClickById(Long id)
    {
        return clickMapper.deleteClickById(id);
    }

    @Override
    public int randomSelect() {
        return clickMapper.randomSelect();
    }
}
